/*
 * DG (DG Gaming Engine)  - Server
 * Copyright (C) 2005  Bob Marks (marksie531@yahoo.com)
 * http://code.google.com/p/dng-gaming
 *
 * This program is free software; you can redistribute it and/or
 * modify it under the terms of the GNU General Public License
 * as published by the Free Software Foundation; either version 2
 * of the License, or (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program; if not, write to the Free Software
 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
 */
package com.dg.gaming.server.data;

/**
 * Data class for the Users object which can be used with IBatis.
 *
 * @author Bob Marks
 * @version Beta 0.3
 */
public class User {

    private long userId;
    private String username;
    private String password;
    private int securityQuestion;
    private String securityAnswer;
    private String yearOfBirth;
    private String email;
    private boolean receiveNewsletter;

    /**
     * Blank constructor.
     */
    public User() {}

    /**
     * Constructor which takes a username.
     *
     * @param username
     */
    public User(long userId) {
        this(userId, null, null);
    }

    /**
     * Create a user with username and password.
     *
     * @param username
     * @param password
     */
    public User(long userId, String username) {
        this(userId, username, null);
    }

    /**
     * Create a user with username and password.
     *
     * @param username
     * @param password
     */
    public User(long userId, String username, String password) {
        this.userId = userId;
        this.username = username;
        this.password = password;
    }


    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public int getSecurityQuestion() {
        return securityQuestion;
    }

    public void setSecurityQuestion(int securityQuestion) {
        this.securityQuestion = securityQuestion;
    }

    public String getSecurityAnswer() {
        return securityAnswer;
    }

    public void setSecurityAnswer(String securityAnswer) {
        this.securityAnswer = securityAnswer;
    }

    public String getYearOfBirth() {
        return yearOfBirth;
    }

    public void setYearOfBirth(String yearOfBirth) {
        this.yearOfBirth = yearOfBirth;
    }

    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email;
    }

    public boolean isReceiveNewsletter() {
        return receiveNewsletter;
    }

    public long getUserId() {
        return userId;
    }

    public void setReceiveNewsletter(boolean receiveNewsletter) {
        this.receiveNewsletter = receiveNewsletter;
    }

    public void setUserId(long userId) {
        this.userId = userId;
    }
}
